﻿using EOrm.Helper;

namespace EOrm
{
    /// <summary>
    /// 命名映射
    /// </summary>
    internal class EOrmName
    {
        /// <summary>
        /// 构造函数
        /// </summary>
        /// <param name="name">名称</param>
        internal EOrmName(string name)
        {
            Name = name;
        }

        /// <summary>
        /// 名称
        /// </summary>
        internal string Name { get; set; }
        /// <summary>
        /// 别名
        /// </summary>
        internal string Alias
        {
            get
            {
                return EOrmBase.IsChangeName ? StringHelper.ToSeparator(Name) : Name;
            }
        }
    }
}
